﻿<UserControl x:Class="LiveTiss.Guias.UserControls.AtendimentoConsulta"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
    xmlns:sdk="http://schemas.microsoft.com/winfx/2006/xaml/presentation/sdk" 
    mc:Ignorable="d"
    xmlns:converter="clr-namespace:LiveTiss.Classes.TypeConverter" Width="910">
    <UserControl.Resources>
        <converter:EnumConverter x:Key="enumConverter"  />
        <DataTemplate x:Key="ContentTemplate">
            <StackPanel Width="910">
                <Grid x:Name="Agrupamento" Margin="0,19,0,0" VerticalAlignment="Top">
                    <Rectangle x:Name="Contorno" RadiusY="6" RadiusX="6" Stroke="#4D898989"/>
                    <TextBlock x:Name="Titulo_Agrupamento" TextWrapping="Wrap" Text="Dados do Atendimento / Procedimento Realizado" Margin="10,10,8,0" VerticalAlignment="Top" FontFamily="Segoe UI Semibold" FontSize="16"/>
                    <StackPanel x:Name="Conteudo_Agrupamento" Margin="12,44,8,0">
                        <Grid Height="53" Margin="0,0,6,0">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="0.024*"/>
                                <ColumnDefinition Width="0.976*"/>
                            </Grid.ColumnDefinitions>
                            <StackPanel x:Name="Data" Grid.ColumnSpan="2" Margin="0" Grid.Column="2">
                                <TextBlock TextWrapping="Wrap" Text="Data do Atendimento:" FontFamily="Segoe UI" FontSize="13.333"/>
                                <sdk:DatePicker Name="dtpDataAtendimento" HorizontalAlignment="Left" Margin="0,6,0,0" SelectedDate="{Binding _dataAtendimento, BindsDirectlyToSource=True, Mode=TwoWay,ValidatesOnDataErrors=True}" />
                            </StackPanel>
                            <TextBlock TextWrapping="Wrap" Text="*" FontFamily="Segoe UI" FontWeight="Bold" FontSize="21.333" Foreground="#FF307852" Height="16" VerticalAlignment="Top" Margin="0,0,3,0" d:LayoutOverrides="Width"/>
                        </Grid>
                        <Grid Height="53" Margin="0,0,6,0">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="0.024*"/>
                                <ColumnDefinition Width="0.976*"/>
                            </Grid.ColumnDefinitions>
                            <StackPanel Grid.ColumnSpan="2" Margin="0" Grid.Row="2" Grid.Column="2">
                                <TextBlock TextWrapping="Wrap" Text="Codigo Tabela:" FontFamily="Segoe UI" FontSize="13.333"/>
                                <ComboBox Name="cbxCodigoTabela" Width="300" Margin="0,6,0,0" SelectedValue="Key" DisplayMemberPath="Value" Height="25" HorizontalAlignment="Left" ItemsSource="{Binding procedimento.Items, Mode=OneWay}"
                                    SelectedIndex="{Binding procedimento.codigoTabela,Converter={StaticResource enumConverter}, ConverterParameter='Tabela', BindsDirectlyToSource=True, Mode=TwoWay,ValidatesOnDataErrors=True}"/>
                            </StackPanel>
                            <TextBlock TextWrapping="Wrap" Text="*" FontFamily="Segoe UI" FontWeight="Bold" FontSize="21.333" Foreground="#FF307852" Height="16" VerticalAlignment="Top" Margin="0,0,3,0" d:LayoutOverrides="Width"/>
                        </Grid>
                        <Grid Height="53" Margin="0,0,6,0">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="0.024*"/>
                                <ColumnDefinition Width="0.976*"/>
                            </Grid.ColumnDefinitions>
                            <StackPanel Grid.ColumnSpan="2" Margin="0" Grid.Row="2" Grid.Column="2">
                                <TextBlock TextWrapping="Wrap" Text="Código Procedimento:" FontFamily="Segoe UI" FontSize="13.333"/>
                                <TextBox Name="txtCodigoProcedimento" Margin="0,6,323,0" MaxLength="10" Text="{Binding procedimento.codigoProcedimento, BindsDirectlyToSource=True, Mode=TwoWay,ValidatesOnDataErrors=True}"/>
                            </StackPanel>
                            <TextBlock TextWrapping="Wrap" Text="*" FontFamily="Segoe UI" FontWeight="Bold" FontSize="21.333" Foreground="#FF307852" Height="16" VerticalAlignment="Top" Margin="0,0,3,0" d:LayoutOverrides="Width"/>
                        </Grid>
                        <Grid Height="53" Margin="0,0,6,0">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="0.024*"/>
                                <ColumnDefinition Width="0.976*"/>
                            </Grid.ColumnDefinitions>
                            <StackPanel Grid.ColumnSpan="2" Margin="0" Grid.Row="2" Grid.Column="2">
                                <TextBlock TextWrapping="Wrap" Text="Tipo de Consulta:" FontFamily="Segoe UI" FontSize="13.333"/>
                                <ComboBox Name="cbxTipoConsulta" Width="300" Margin="0,6,0,0" HorizontalAlignment="Left" Height="25" SelectedValue="Key" DisplayMemberPath="Value" ItemsSource="{Binding consultaItems, Mode=OneWay,ValidatesOnDataErrors=True}"
                                    SelectedIndex="{Binding tipoConsulta,Converter={StaticResource enumConverter}, ConverterParameter='TipoConsulta', BindsDirectlyToSource=True, Mode=TwoWay,ValidatesOnDataErrors=True}"/>
                            </StackPanel>
                            <TextBlock TextWrapping="Wrap" Text="*" FontFamily="Segoe UI" FontWeight="Bold" FontSize="21.333" Foreground="#FF307852" Height="16" VerticalAlignment="Top" Margin="0,0,3,0" d:LayoutOverrides="Width"/>
                        </Grid>
                        <Grid Height="53" Margin="0,0,6,0">
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="0.024*"/>
                                <ColumnDefinition Width="0.976*"/>
                            </Grid.ColumnDefinitions>
                            <StackPanel Grid.ColumnSpan="2" Margin="0" Grid.Row="2" Grid.Column="2">
                                <TextBlock TextWrapping="Wrap" Text="Tipo de Saída:" FontFamily="Segoe UI" FontSize="13.333"/>
                                <ComboBox Name="cbxTipoSaida" Width="300" Margin="0,6,0,0" HorizontalAlignment="Left" Height="25" SelectedValue="Key" DisplayMemberPath="Value" ItemsSource="{Binding saidaItems, Mode=OneWay}"
                                    SelectedIndex="{Binding tipoSaida,Converter={StaticResource enumConverter}, ConverterParameter='TipoSaidaGuiaConsulta', BindsDirectlyToSource=True, Mode=TwoWay,ValidatesOnDataErrors=True}"/>
                            </StackPanel>
                            <TextBlock TextWrapping="Wrap" Text="*" FontFamily="Segoe UI" FontWeight="Bold" FontSize="21.333" Foreground="#FF307852" Height="16" VerticalAlignment="Top" Margin="0,0,3,0" d:LayoutOverrides="Width"/>
                        </Grid>
                    </StackPanel>
                </Grid>
            </StackPanel>
        </DataTemplate>
    </UserControl.Resources>
    <ContentControl Name="content" ContentTemplate="{StaticResource ContentTemplate}" />
</UserControl>
